#include <stdio.h>
#include "catch.hpp"

//int main()
//{
//    printf("hello, world!\n");
//
//    return 0;
//}

unsigned int Factorial( unsigned int number ) {
    return number <= 1 ? number : Factorial(number-1)*number;
}

TEST_CASE( "Factorials are computed", "[factorial]" ) {
    REQUIRE( Factorial(1) == 1 );
    REQUIRE( Factorial(2) == 2 );
    REQUIRE( Factorial(3) == 6 );
    REQUIRE( Factorial(10) == 3628800 );
    printf("base\n");
    SECTION("section1\n"){
        printf("section1\n");
        SECTION("section11\n"){
            printf("section11\n");
        }
        SECTION("section12\n"){
            printf("section12\n");
        }
    }
    SECTION("section2\n"){
        printf("section2\n");
        SECTION("section21\n"){
            printf("section21\n");
        }
        SECTION("section22\n"){
            printf("section22\n");
        }
    }
}
